static float hilbcoefs[7][6][5] = 
{
  //192k
  {
    {0.20962426066398620605, -1.20915770530700683594, 1., -1.20915770530700683594, 0.20962426066398620605},
    {0.74041956663131713867, -1.73927283287048339844, 1., -1.73927283287048339844, 0.74041956663131713867},
    {0.91253882646560668945, -1.91126072406768798828, 1., -1.91126072406768798828, 0.91253882646560668945},
    {-0.38689124584197998047, -0.61026799678802490234, 1., -0.61026799678802490234, -0.38689124584197998047},
    {0.53540545701980590820, -1.53123700618743896484, 1., -1.53123700618743896484, 0.53540545701980590820},
    {0.83237081766128540039, -1.82746553421020507812, 1., -1.82746553421020507812, 0.83237081766128540039}
  },
  //96k
  {
    {0.20962426066398620605, -1.20915770530700683594, 1., -1.20915770530700683594, 0.20962426066398620605},
    {0.74041956663131713867, -1.73927283287048339844, 1., -1.73927283287048339844, 0.74041956663131713867},
    {0.91253882646560668945, -1.91126072406768798828, 1., -1.91126072406768798828, 0.91253882646560668945},
    {-0.38689124584197998047, -0.61026799678802490234, 1., -0.61026799678802490234, -0.38689124584197998047},
    {0.53540545701980590820, -1.53123700618743896484, 1., -1.53123700618743896484, 0.53540545701980590820},
    {0.83237081766128540039, -1.82746553421020507812, 1., -1.82746553421020507812, 0.83237081766128540039}
  },
  //88.2k
  {
    {0.16879443824291229248, -1.16826045513153076172, 1., -1.16826045513153076172, 0.16879443824291229248},
    {0.72068428993225097656, -1.71934115886688232422, 1., -1.71934115886688232422, 0.72068428993225097656},
    {0.90517652034759521484, -1.90366828441619873047, 1., -1.90366828441619873047, 0.90517652034759521484},
    {-0.42214190959930419922, -0.57468748092651367188, 1., -0.57468748092651367188, -0.42214190959930419922},
    {0.50459146499633789062, -1.49975347518920898438, 1., -1.49975347518920898438, 0.50459146499633789062},
    {0.81892961263656616211, -1.81316232681274414062, 1., -1.81316232681274414062, 0.81892961263656616211}
  },
  //48k
  {
    {-0.13271854817867279053, -0.86594426631927490234, 1., -0.86594426631927490234, -0.13271854817867279053},
    {0.54082983732223510742, -1.53677272796630859375, 1., -1.53677272796630859375, 0.54082983732223510742},
    {0.83256042003631591797, -1.82766675949096679688, 1., -1.82766675949096679688, 0.83256042003631591797},
    {-0.63589376211166381836, -0.35740464925765991211, 1., -0.35740464925765991211, -0.63589376211166381836},
    {0.24787813425064086914, -1.23438167572021484375, 1., -1.23438167572021484375, 0.24787813425064086914},
    {0.69171458482742309570, -1.67367196083068847656, 1., -1.67367196083068847656, 0.69171458482742309570}
  },
  //44.1k
  {
    {-0.17401643097400665283, -0.82447504997253417969, 1., -0.82447504997253417969, -0.17401643097400665283},
    {0.51025813817977905273, -1.50554823875427246094, 1., -1.50554823875427246094, 0.51025813817977905273},
    {0.81913280487060546875, -1.81337928771972656250, 1., -1.81337928771972656250, 0.81913280487060546875},
    {-0.65997588634490966797, -0.33262246847152709961, 1., -0.33262246847152709961, -0.65997588634490966797},
    {0.20819064974784851074, -1.19272553920745849609, 1., -1.19272553920745849609, 0.20819064974784851074},
    {0.66923570632934570312, -1.64816546440124511719, 1., -1.64816546440124511719, 0.66923570632934570312}
  },
  //32k
  {
    {-0.32368427515029907227, -0.67397177219390869141, 1., -0.67397177219390869141, -0.32368427515029907227},
    {0.38286918401718139648, -1.37469005584716796875, 1., -1.37469005584716796875, 0.38286918401718139648},
    {0.75928509235382080078, -1.74873208999633789062, 1., -1.74873208999633789062, 0.75928509235382080078},
    {-0.73899567127227783203, -0.25031834840774536133, 1., -0.25031834840774536133, -0.73899567127227783203},
    {0.05373485758900642395, -1.02826452255249023438, 1., -1.02826452255249023438, 0.05373485758900642395},
    {0.57289743423461914062, -1.53540277481079101562, 1., -1.53540277481079101562, 0.57289743423461914062}
  },
  //22.05k
  {
    {-0.47848016023635864258, -0.51772046089172363281, 1., -0.51772046089172363281, -0.47848016023635864258},
    {0.21541087329387664795, -1.20031988620758056641, 1., -1.20031988620758056641, 0.21541087329387664795},
    {0.66957312822341918945, -1.64855051040649414062, 1., -1.64855051040649414062, 0.66957312822341918945},
    {-0.80870652198791503906, -0.17516374588012695312, 1., -0.17516374588012695312, -0.80870652198791503906},
    {-0.12512592971324920654, -0.83092355728149414062, 1., -0.83092355728149414062, -0.12512592971324920654},
    {0.43994483351707458496, -1.36859226226806640625, 1., -1.36859226226806640625, 0.43994483351707458496}
  }
};

float gethilbertcoef(int sr, int filter, int idx)
{
  switch(sr)
  {
    case 192000: return hilbcoefs[0][filter][idx];
    case 96000: return hilbcoefs[1][filter][idx];
    case 88200: return hilbcoefs[2][filter][idx];
    case 48000: return hilbcoefs[3][filter][idx];
    case 44100: return hilbcoefs[4][filter][idx];
    case 32000: return hilbcoefs[5][filter][idx];
    case 22050: return hilbcoefs[6][filter][idx];
    default: return hilbcoefs[4][filter][idx];
  }
}
